body {
    font-family: Arial, sans-serif;
    background: linear-gradient(135deg, #1a2a6c, #4b6cb7);
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    overflow: hidden;
}

.login-container {
    background-color: rgba(255, 255, 255, 0.9);
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    width: 350px;
    position: relative;
    z-index: 2;
}

.terminal-container {
    display: none;
    width: 95%;
    height: 95vh;
    background-color: #1e1e1e;
    border-radius: 10px;
    overflow: hidden;
    flex-direction: column;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    position: relative;
}

h2 {
    text-align: center;
    color: #333;
    margin-bottom: 20px;
    font-weight: 600;
}

.form-group {
    margin-bottom: 18px;
}

label {
    display: block;
    margin-bottom: 7px;
    color: #555;
    font-weight: 500;
}

input {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    box-sizing: border-box;
    font-size: 16px;
    transition: border-color 0.3s;
}

input:focus {
    border-color: #1890ff;
    outline: none;
    box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.2);
}

button {
    width: 100%;
    padding: 12px;
    background: linear-gradient(45deg, #1890ff, #0066cc);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s;
    box-shadow: 0 4px 6px rgba(24, 144, 255, 0.3);
}

button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 8px rgba(24, 144, 255, 0.4);
}

.remember-me {
    display: flex;
    align-items: center;
    margin-bottom: 18px;
}

.remember-me input {
    width: auto;
    margin-right: 10px;
}

#terminal {
    flex-grow: 1;
    padding: 10px;
    overflow-y: auto;
    font-size: 14px;
}

.terminal-header {
    background: linear-gradient(to right, #2c3e50, #4a6581);
    color: white;
    padding: 12px 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 16px;
    font-weight: 600;
}

.terminal-controls {
    display: flex;
    gap: 8px;
}

.terminal-controls button {
    width: auto;
    padding: 7px 15px;
    font-size: 14px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 5px;
    box-shadow: none;
}

.terminal-controls button:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: none;
}

.error-message {
    color: #ff4d4f;
    text-align: center;
    margin-top: 12px;
    font-weight: 500;
}

.history-list {
    margin-top: 25px;
    border-top: 1px solid #eee;
    padding-top: 18px;
}

.history-list h3 {
    margin-top: 0;
    font-size: 18px;
    color: #333;
}

.history-item {
    padding: 10px;
    border-radius: 6px;
    border-bottom: 1px solid #eee;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.history-item:before {
    content: "→";
    color: #1890ff;
}

.history-item:hover {
    background-color: #e6f7ff;
    transform: translateX(5px);
}

/* Additional decorations */
.bg-elements {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.bg-element {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
}

.connection-details {
    position: absolute;
    bottom: 20px;
    right: 20px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 14px;
    z-index: 2;
}

.status-indicator {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: #52c41a;
    margin-right: 8px;
}

.xterm {
    padding: 15px !important;
}

.xterm .xterm-viewport {
    background-color: #1e1e1e !important;
    overflow-y: hidden !important;
}

.xterm .xterm-screen .xterm-text-layer {
    font-family: 'Fira Code', 'Consolas', 'Courier New', monospace !important;
    font-size: 15px !important;
    line-height: 1.1 !important;
}

.footer-info {
    position: absolute;
    bottom: 10px;
    left: 20px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 12px;
}

.bg-shapes {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    overflow: hidden;
}

.shape {
    position: absolute;
    background: rgba(255, 255, 255, 0.03);
}

.shape-circle {
    border-radius: 50%;
}

.shape-square {
    transform: rotate(45deg);
}

/* ---------- 手机端适配 ---------- */
@media (max-width: 600px) {
    body {
        padding: 0;
        margin: 0;
        height: 100vh;
        justify-content: flex-start;
        align-items: stretch;
    }

    .login-container {
        width: 100%;
        height: 100%;
        border-radius: 0;
        box-shadow: none;
        padding: 40px 20px;
        box-sizing: border-box;
    }

    .terminal-container {
        width: 100%;
        height: 100vh;
        border-radius: 0;
        box-shadow: none;
    }

    .terminal-header {
        font-size: 14px;
        padding: 10px;
    }

    .terminal-controls {
        flex-direction: column;
        gap: 4px;
    }

    .terminal-controls button {
        font-size: 12px;
        padding: 5px 8px;
    }

    #terminal {
        padding: 5px;
    }

    .footer-info {
        position: static;
        margin-top: auto;
        padding: 5px 10px;
        font-size: 10px;
        text-align: center;
        background: #1e1e1e;
        color: rgba(255, 255, 255, 0.5);
    }

    .history-item {
        font-size: 14px;
        padding: 8px;
    }

    .history-list {
        max-height: 150px;
        overflow-y: auto;
    }
}


